package com.ybwh.springboot2.controller;

//import com.ybwh.springboot2.clearing.entity.SysFlow;
import com.ybwh.springboot2.common.RespData;
import org.springframework.stereotype.Controller;
import org.springframework.validation.BindingResult;
import org.springframework.validation.ObjectError;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.ModelAttribute;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 * <p>
 * 前端控制器
 * </p>
 *
 * @author saytime
 * @since 2018-12-06
 */
//@Controller
//@RequestMapping("/area")
public class AreaController {

//	@ResponseBody
//	@RequestMapping("/validate")
//	public RespData<Object> validate(@Validated @ModelAttribute SysFlow areaVo, BindingResult bindingResult) {
//		if (bindingResult.hasErrors()) {
//			for(ObjectError error : bindingResult.getAllErrors()) {
//				return RespData.failedResp(error.getDefaultMessage());
//			}
//		}
//
//		return RespData.successResp(null);
//	}

}
